#pragma once

#include <iostream>
#include <unistd.h>
#include <functional>

class Task
{
public:
    typedef std::function<int (int, int)> func_t;
    Task(){}
    Task(int x, int y, func_t func)
        :_x(x)
        ,_y(y)
        ,_func(func)
    {}
    int operator()()
    {
        return _func(_x, _y);
    }    
public:
    int _x;
    int _y;
    func_t _func;
};